#!/usr/bin/env python3
# -*-coding: utf-8 -*-
# Desc: json handle

import json


d = {
        'a': 1,
        'b': 2,
        'c': True,
        'd': 'ssfan'
        }

tojson = json.dumps(d)  # dict to json
todict = json.loads(tojson) # json to dict 

print('dict to json: ', tojson)
print('json to dice: ', todict)

